﻿using System;
using JTLeigh.Commerce.Spencer.Features.ProductImages.Common.Entities;

namespace JTLeigh.Commerce.Spencer.Features.ProductImages.Business.Services
{

	/// <summary>
	/// Service used to retrieve product image metadata, including sizes and views.
	/// </summary>
	public interface IProductImageMetadataService
	{

		#region Methods

		/// <summary>
		/// Gets a localized product image size by size identifier and culture identifier.
		/// </summary>
		/// <param name="tenantId">The tenant identifier <see cref="Guid"/> of the tenant whose
		/// product image size is to be retrieved.</param>
		/// <param name="sizeId">The size identifier <see cref="Guid"/> of the size to retrieve.</param>
		/// <param name="cultureId">The <see cref="Int32"/> LCID of the culture to use to retrieve
		/// culture-specific resources.</param>
		/// <returns>A <see cref="LocalizedProductImageSize"/>.</returns>
		LocalizedProductImageSize GetProductImageSizeBySizeId(Guid tenantId, Guid sizeId, int cultureId);

		/// <summary>
		/// Gets a localized product image size by well-known size code and culture identifier.
		/// </summary>
		/// <param name="tenantId">The tenant identifier <see cref="Guid"/> of the tenant whose
		/// product image size is to be retrieved.</param>
		/// <param name="wellKnownSizeCode">The well-known size code <see cref="Byte"/> of the size 
		/// to retrieve.</param>
		/// <param name="cultureId">The <see cref="Int32"/> LCID of the culture to use to retrieve
		/// culture-specific resources.</param>
		/// <returns>A <see cref="LocalizedProductImageSize"/>.</returns>
		LocalizedProductImageSize GetProductImageSizeByWellKnownSizeCode(Guid tenantId, byte wellKnownSizeCode, int cultureId);

		/// <summary>
		/// Gets a localized product image view by view identifier and culture identifier.
		/// </summary>
		/// <param name="tenantId">The tenant identifier <see cref="Guid"/> of the tenant whose
		/// product image view is to be retrieved.</param>
		/// <param name="viewId">The view identifier <see cref="Guid"/> of the view to retrieve.</param>
		/// <param name="cultureId">The <see cref="Int32"/> LCID of the culture to use to retrieve
		/// culture-specific resources.</param>
		/// <returns>A <see cref="LocalizedProductImageView"/>.</returns>
		LocalizedProductImageView GetProductImageViewByViewId(Guid tenantId, Guid viewId, int cultureId);

		/// <summary>
		/// Gets a localized product image view by well-known view code and culture identifier.
		/// </summary>
		/// <param name="tenantId">The tenant identifier <see cref="Guid"/> of the tenant whose
		/// product image view is to be retrieved.</param>
		/// <param name="wellKnownViewCode">The well-known view code <see cref="Byte"/> of the view 
		/// to retrieve.</param>
		/// <param name="cultureId">The <see cref="Int32"/> LCID of the culture to use to retrieve
		/// culture-specific resources.</param>
		/// <returns>A <see cref="LocalizedProductImageView"/>.</returns>
		LocalizedProductImageView GetProductImageViewByWellKnownViewCode(Guid tenantId, byte wellKnownViewCode, int cultureId);

		#endregion // Methods

	}

}
